Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Copier Gain feature for DMIC interface #9537

Merged
merged 2 commits into from
Oct 4, 2024

Conversation

iganakov
Copy link
Contributor

@iganakov iganakov commented Oct 2, 2024

Apply Copier Gain feature, introduced in #9323, to DMIC interface.

Add complete DMIC configuration blob definitions.

Use DMA Control IPC message to update gain coefficients in runtime.

Define common IPC4 Dmic blob structures

Signed-off-by: Ievgen Ganakov <[email protected]>
Copy link
Member

@lgirdwood lgirdwood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but can you also explain when/how DMA control IPC is used. Thanks

src/include/ipc4/base_fw.h Show resolved Hide resolved
@iganakov iganakov force-pushed the iganakov/dmic_enable_gain branch from 60f3a5d to 9babc61 Compare October 3, 2024 11:09
@kv2019i kv2019i requested a review from singalsu October 3, 2024 12:44
Copy link
Collaborator

@kv2019i kv2019i left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No showstoppers. I'd like @singalsu to review the new dmic blob addition so this is not conflicting with any other tool.

@@ -322,6 +322,9 @@ int copier_dai_create(struct comp_dev *dev, struct copier_data *cd,
return -EINVAL;
}
dai.out_fmt = &copier->out_fmt;
#if CONFIG_COPIER_GAIN
dai.apply_gain = true;
#endif
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens when no configuration is passed from the host (like in case of Linux driver)? Unity gain applied? This seems to be enabled by default.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kv2019i Yes, unity gain applied (gain = 1)

src/include/ipc4/base_fw.h Show resolved Hide resolved
Enable gain for DMIC interface. Configure gain feature with
parameters received in DMIC BLOB.

Add support for runtime DMIC gain parameters update using
DMA Control IPC.

Signed-off-by: Ievgen Ganakov <[email protected]>
@iganakov iganakov force-pushed the iganakov/dmic_enable_gain branch from 9babc61 to 0fd9030 Compare October 3, 2024 13:58
Copy link
Collaborator

@singalsu singalsu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks OK to me. The dmic structs are same though here more detailed based on updated documentation vs. the other dmic.h. It could be cleaned up later to avoid duplication.

@mwasko mwasko merged commit 9cdef9f into thesofproject:main Oct 4, 2024
43 of 47 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants